Release 10.1A: OpenEdge Development:
Progress 4GL Reference


INPUT-OUTPUT CLOSE statement


(NT, UNIX only)

Closes a specified or default stream opened by an INPUT-OUTPUT THROUGH statement.

Syntax

INPUT-OUTPUT [ STREAM stream ] CLOSE 

STREAM stream

The name of the stream you want to close. If you do not name a stream, Progress closes the default stream used by an INPUT-OUTPUT THROUGH statement.

Example

This procedure uses a C program to recalculate the price of each item in inventory. Specifically, the C program increases the price of each item by 3% or by 50 cents, whichever is greater. The INPUT-OUTPUT THROUGH statement tells the procedure to get its input from, and send its output to, the r-iothru.p procedure. The INPUT-OUTPUT CLOSE statement resets the input source to the terminal and the output destination to the terminal.

r-iothru.p
FOR EACH item WHERE item-num < 10:
    DISPLAY item-num price LABEL "Price before recalculation".
END.

INPUT-OUTPUT THROUGH r-iothru UNBUFFERED.

FOR EACH item WHERE item-num < 10:
    EXPORT price.
    SET price.
END.

INPUT-OUTPUT CLOSE.

FOR EACH item WHERE item-num < 10 WITH COLUMN 40:
    DISPLAY item-num price LABEL "Price after recalculation".
END. 

Note

For more information, see OpenEdge Development: Programming Interfaces .

See also

DEFINE STREAM statement, INPUT-OUTPUT THROUGH statement


Copyright © 2005 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095